ALTER VIEW [dbo].[View_Demo_School]
AS
SELECT
       ds.SchoolGUID,
       ds.SchoolCode,
       ds.SchoolName,
       ds.ParentSchoolGUID,
       ds.SchoolOrderCode,
       ds.SchoolIcon,
       ds.TenantId,
       ds.IsDeleted,
       ds.CreateTime,
       ds.CreateGUID,
       ds.CreatedName,
       ds.ModifiedTime,
       ds.ModifiedGUID,
       ds.ModifiedName,
       ds.ApproveState,
       ds.ApproveGUID,
       ds.ApproveTime,
       ds.BuUnitGUID,
	   ds.SchoolFullCode,
	 dsc.SchoolName AS ParentSchoolName
FROM dbo.Demo_School ds
LEFT JOIN	dbo.Demo_School dsc ON ds.ParentSchoolGUID=dsc.SchoolGUID